package com.webservice.xmloper.managercode;

import java.util.ArrayList;
import java.util.List;

import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamImplicit;

@XStreamAlias("command")
public class CommandQuery {
	private String commandId;
	private Integer type;
	@XStreamImplicit
	private List<SmcsRule> rules = new ArrayList<SmcsRule>();
	private SmcsAction action;
	private SmcsTime time;
	private SmcsAckRange range;
	private Privilege privilege;
	
	public void addRule(SmcsRule rule) {
		this.rules.add(rule);
	}
	
	public String getCommandId() {
		return commandId;
	}

	public void setCommandId(String commandId) {
		this.commandId = commandId;
	}

	public SmcsAckRange getRange() {
		return range;
	}

	public void setRange(SmcsAckRange range) {
		this.range = range;
	}

	public Privilege getPrivilege() {
		return privilege;
	}

	public void setPrivilege(Privilege privilege) {
		this.privilege = privilege;
	}

	public Integer getType() {
		return type;
	}
	public void setType(Integer type) {
		this.type = type;
	}
	
	public List<SmcsRule> getRules() {
		return rules;
	}
	public void setRules(List<SmcsRule> rules) {
		this.rules = rules;
	}
	public SmcsAction getAction() {
		return action;
	}
	public void setAction(SmcsAction action) {
		this.action = action;
	}
	public SmcsTime getTime() {
		return time;
	}
	public void setTime(SmcsTime time) {
		this.time = time;
	}
}
